/*
 * Copyright (c) 2021 Talkweb Co., Ltd.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
#ifndef _NFC_I2C_H
#define _NFC_I2C_H
#include "nfc_adapt.h"
#include "nfc_ndef.h"

/**
 * @brief I2C写NFC EEPROM函数
 * @param addr 写入的EEPROM内存起始地址
 * @param mem 带写入的数据信息
 * @return 返回TRUE表示写入数据成功
 */
BOOL NfcI2CWriteMem(unsigned int addr, MemFrame *mem);

/**
 * @brief I2C读NFC EEPROM函数
 * @param addr 读取的EEPROM内存起始地址
 * @param readSize 读取的字节数
 * @param memBuf 读取的数据缓冲区
 * @return 返回TRUE表示读取数据成功
 */
BOOL NfcI2CReadMem(unsigned int addr, unsigned int readSize, unsigned char *memBuf);

#endif
